package com.example.demo.pojo.vo;

import com.example.demo.pojo.entity.ExamCategory;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.ArrayList;
import java.util.List;

/**
 * @Description: 试卷信息下的题目种类和题目间的关系
 * @author: fjh
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class ExamCategoryVO {
    private Integer examCategoryId;
    private Integer categoryId;
    private Integer examId;
    private String description;
    private Integer questionNumber;
    private Integer questionScore;
    private String categoryName;
    List<ExamQuestionVO> examQuestionList=new ArrayList<>();
    public void initExamCategory(ExamCategory examCategory){
        this.examCategoryId=examCategory.getId();
        this.categoryId=examCategory.getCategoryId();
        this.examId=examCategory.getExamId();
        this.description=examCategory.getDescription();
        this.questionNumber=examCategory.getQuestionNumber();
        this.questionScore=examCategory.getQuestionScore();
    }
}
